Skip to content

ci(workflows): presence-gate mirror SSH steps + correct registry-verify licence#367

Merged
hyperpolymath merged 2 commits into
mainfrom
claude/nice-ptolemy-lNB8E
Jun 3, 2026
Merged

ci(workflows): presence-gate mirror SSH steps + correct registry-verify licence#367
hyperpolymath merged 2 commits into
mainfrom
claude/nice-ptolemy-lNB8E

Conversation

@hyperpolymath
Copy link
Copy Markdown
Owner

What

Two workflow-hardening / hygiene fixes flagged by the Hypatia scan.

1. mirror-reusable.yml — presence-gate the SSH secret (Hypatia secret_action_without_presence_gate, high)

Each forge job (GitLab, Bitbucket, Codeberg, SourceHut, Disroot, Gitea) ran webfactory/ssh-agent gated only on vars.<FORGE>_MIRROR_ENABLED, so an enabled-but-keyless mirror would feed an empty key to the action and fail. Added if: ${{ secrets.<FORGE>_SSH_KEY != '' }} to both the ssh-agent step and its push step in all 6 jobs — matching the existing Radicle pattern in the same file. Now a mirror with no configured key is a clean no-op instead of a hard failure.

2. registry-verify.yml — licence correction (owner-directed)

SPDX AGPL-3.0-or-laterMPL-2.0. It was the only one of 28 workflows on AGPL; this aligns it with its siblings and the repo's sole-owner MPL-2.0 classification, and clears Hypatia's agpl_license finding.

Not changed (Hypatia false positives, documented)

  • scorecard_publish_with_run_step on scorecard-enforcer.yml — the publish job (scorecard) is already uses-only, with the threshold check split into a downstream check-score job (there's a comment documenting exactly this). Hypatia flags run: steps elsewhere in the file without scoping to the job.
  • unpinned_action — every uses: is SHA-pinned; Hypatia truncates the SHA and mis-flags. (Foundational fix tracked for the Hypatia repo.)

Verification

  • Both files parse (PyYAML); registry/topology still in sync.
  • Diff: +13 / −1, two files.

Flagged, not swept

Other AGPL-3.0-or-later SPDX headers remain in scripts/*.sh and .github/FUNDING.yml. Per the manual-only / no-bulk-SPDX guardrail I did not sweep them — surfacing for an explicit decision on whether they should also go to MPL-2.0.

https://claude.ai/code/session_01AmPXB2dA2wCcabo8BXwS28


Generated by Claude Code

…fy licence

- mirror-reusable.yml: gate each forge's webfactory/ssh-agent step AND its push step on secrets.<FORGE>_SSH_KEY != '' (matching the existing Radicle pattern). Resolves Hypatia secret_action_without_presence_gate (high) and makes an enabled-but-keyless mirror a clean no-op rather than a hard failure.

- registry-verify.yml: SPDX AGPL-3.0-or-later -> MPL-2.0 (owner-directed; aligns with its 27 sibling workflows; clears Hypatia agpl_license).

Note: scorecard_publish_with_run_step on scorecard-enforcer.yml is a Hypatia false positive — the publish job is already uses-only with the threshold check split into a downstream check-score job.

https://claude.ai/code/session_01AmPXB2dA2wCcabo8BXwS28
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 3, 2026

🔍 Hypatia Security Scan

Findings: 141 issues detected

Severity Count
🔴 Critical 64
🟠 High 56
🟡 Medium 21

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Action for the check script)\n        uses: actions/checkout@de0f needs attention",
    "type": "unpinned_action",
    "file": "governance-reusable.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Action for the check script)\n        uses: actions/checkout@de0f needs attention",
    "type": "unpinned_action",
    "file": "governance-reusable.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in governance.yml",
    "type": "missing_timeout_minutes",
    "file": "governance.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in mirror.yml",
    "type": "missing_timeout_minutes",
    "file": "mirror.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in scorecard.yml",
    "type": "missing_timeout_minutes",
    "file": "scorecard.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in secret-scanner.yml",
    "type": "missing_timeout_minutes",
    "file": "secret-scanner.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in scorecard-enforcer.yml",
    "type": "scorecard_publish_with_run_step",
    "file": "scorecard-enforcer.yml",
    "action": "split_scorecard_publish_job",
    "rule_module": "workflow_audit",
    "severity": "high"
  },
  {
    "reason": "Issue in instant-sync.yml",
    "type": "secret_action_without_presence_gate",
    "file": "instant-sync.yml",
    "action": "peter-evans/repository-dispatch",
    "rule_module": "workflow_audit",
    "severity": "high"
  },
  {
    "reason": "Python file detected -- banned language",
    "type": "banned_language_file",
    "file": "/home/runner/work/standards/standards/a2ml-templates/state-scm-to-v2.py",
    "action": "flag",
    "rule_module": "cicd_rules",
    "severity": "critical"
  },
  {
    "reason": "TypeScript file detected -- banned language",
    "type": "banned_language_file",
    "file": "/home/runner/work/standards/standards/lol/test/vitest.config.ts",
    "action": "flag",
    "rule_module": "cicd_rules",
    "severity": "critical"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

@hyperpolymath hyperpolymath marked this pull request as ready for review June 3, 2026 23:24
@hyperpolymath hyperpolymath enabled auto-merge (squash) June 3, 2026 23:26
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 3, 2026

🔍 Hypatia Security Scan

Findings: 141 issues detected

Severity Count
🔴 Critical 64
🟠 High 56
🟡 Medium 21

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Action for the check script)\n        uses: actions/checkout@de0f needs attention",
    "type": "unpinned_action",
    "file": "governance-reusable.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Action for the check script)\n        uses: actions/checkout@de0f needs attention",
    "type": "unpinned_action",
    "file": "governance-reusable.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in governance.yml",
    "type": "missing_timeout_minutes",
    "file": "governance.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in mirror.yml",
    "type": "missing_timeout_minutes",
    "file": "mirror.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in scorecard.yml",
    "type": "missing_timeout_minutes",
    "file": "scorecard.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in secret-scanner.yml",
    "type": "missing_timeout_minutes",
    "file": "secret-scanner.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in scorecard-enforcer.yml",
    "type": "scorecard_publish_with_run_step",
    "file": "scorecard-enforcer.yml",
    "action": "split_scorecard_publish_job",
    "rule_module": "workflow_audit",
    "severity": "high"
  },
  {
    "reason": "Issue in instant-sync.yml",
    "type": "secret_action_without_presence_gate",
    "file": "instant-sync.yml",
    "action": "peter-evans/repository-dispatch",
    "rule_module": "workflow_audit",
    "severity": "high"
  },
  {
    "reason": "Python file detected -- banned language",
    "type": "banned_language_file",
    "file": "/home/runner/work/standards/standards/a2ml-templates/state-scm-to-v2.py",
    "action": "flag",
    "rule_module": "cicd_rules",
    "severity": "critical"
  },
  {
    "reason": "TypeScript file detected -- banned language",
    "type": "banned_language_file",
    "file": "/home/runner/work/standards/standards/lol/test/vitest.config.ts",
    "action": "flag",
    "rule_module": "cicd_rules",
    "severity": "critical"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

@hyperpolymath hyperpolymath merged commit e59affd into main Jun 3, 2026
22 checks passed
@hyperpolymath hyperpolymath deleted the claude/nice-ptolemy-lNB8E branch June 3, 2026 23:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants